package com.uniledger.exchange.home.scheme;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.widget.Button;
import android.widget.FrameLayout;

import com.uniledger.commonlib.numberkeyboard.KeyboardUtil;
import com.uniledger.exchange.R;
import com.uniledger.exchange.bank.AddBankActivity;
import com.uniledger.exchange.bank.MangerBankActivity;
import com.uniledger.exchange.base.activity.BaseActivity;
import com.uniledger.exchange.contact.AddContactActivity;
import com.uniledger.exchange.contact.ContactFragment;
import com.uniledger.exchange.contact.UniContact;
import com.uniledger.exchange.home.scheme.fragment.transfer.OnTransferListener;

import java.util.Map;

import butterknife.BindString;


/**
 * 联系人页面
 */
public class ContactActivity extends BaseActivity implements OnTransferListener{

    public static void start(Activity activity) {
        Intent intent = new Intent(activity, ContactActivity.class);
        activity.startActivity(intent);
    }

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_contact);
        getSupportFragmentManager()
                .beginTransaction()
                .add(R.id.container, ContactFragment.newInstance("", ""))
                .commit();
    }

    @BindString(R.string.friend_bar_title)
    String title;

    @Override
    public void initBar() {
        super.initBar();
        toolbar.setTitle(title);
    }

    @Override
    public void getParams() {
    }

    @Override
    public KeyboardUtil getKeyboard() {
        return null;
    }

    @Override
    public void transfer(Map<String,String> map) {

    }

    @Override
    public void confirm() {

    }

    @Override
    public void select(UniContact contact) {

    }

    @Override
    public FrameLayout getContainer() {
        return null;
    }


//    @Override
//    public boolean onCreateOptionsMenu(Menu menu) {
//        MenuInflater inflater = getMenuInflater();
//        inflater.inflate(R.menu.menu_manger_friend, menu);
//        return true;
//    }
//
//    @Override
//    public boolean onOptionsItemSelected(MenuItem item) {
//        if (item.getItemId() == R.id.manger_friend_add) {
//            //TODO 添加好友
//            AddContactActivity.start(ContactActivity.this);
//            return true;
//        } else {
//            return super.onOptionsItemSelected(item);
//        }
//    }

}
